#ifndef COLORWHEELWIDGET_H
#define COLORWHEELWIDGET_H

#include <QFrame>
#include <QImage>

class ColorWheel : public QFrame
{
   Q_OBJECT
public:
   explicit ColorWheel(QWidget *parent = 0);
   void mouseReleaseEvent(QMouseEvent *event);
   void mousePressEvent(QMouseEvent *event);
   void mouseMoveEvent(QMouseEvent *event);
   void paintEvent(QPaintEvent *paintEvent);
   QColor selectedColor();

signals:
   void newColorSelected(QColor value);

public slots:

private:
   void setTempColor(const QColor &color);

   QImage mColorWheelImage;
   QString mFilename;
   QColor mSelectedColor;
   QPointF mIndicatorPosition;
   bool mMovingIndicator;
};

#endif // COLORWHEELWIDGET_H
